//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package com.itheima.pinda.authority.dto.auth;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;

@ApiModel(
        value = "RoleOrgSaveDTO",
        description = "角色组织关系"
)
public class RoleOrgSaveDTO implements Serializable {
    private static final long serialVersionUID = 1L;
    @ApiModelProperty("角色ID")
    private Long roleId;
    @ApiModelProperty("组织ID")
    private Long orgId;

    public static RoleOrgSaveDTO.RoleOrgSaveDTOBuilder builder() {
        return new RoleOrgSaveDTO.RoleOrgSaveDTOBuilder();
    }

    public Long getRoleId() {
        return this.roleId;
    }

    public Long getOrgId() {
        return this.orgId;
    }

    public RoleOrgSaveDTO setRoleId(final Long roleId) {
        this.roleId = roleId;
        return this;
    }

    public RoleOrgSaveDTO setOrgId(final Long orgId) {
        this.orgId = orgId;
        return this;
    }

    public RoleOrgSaveDTO() {
    }

    public RoleOrgSaveDTO(final Long roleId, final Long orgId) {
        this.roleId = roleId;
        this.orgId = orgId;
    }

    @Override
    public String toString() {
        return "RoleOrgSaveDTO(super=" + super.toString() + ", roleId=" + this.getRoleId() + ", orgId=" + this.getOrgId() + ")";
    }

    @Override
    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        } else if (!(o instanceof RoleOrgSaveDTO)) {
            return false;
        } else {
            RoleOrgSaveDTO other = (RoleOrgSaveDTO)o;
            if (!other.canEqual(this)) {
                return false;
            } else {
                Object this$roleId = this.getRoleId();
                Object other$roleId = other.getRoleId();
                if (this$roleId == null) {
                    if (other$roleId != null) {
                        return false;
                    }
                } else if (!this$roleId.equals(other$roleId)) {
                    return false;
                }

                Object this$orgId = this.getOrgId();
                Object other$orgId = other.getOrgId();
                if (this$orgId == null) {
                    if (other$orgId != null) {
                        return false;
                    }
                } else if (!this$orgId.equals(other$orgId)) {
                    return false;
                }

                return true;
            }
        }
    }

    protected boolean canEqual(final Object other) {
        return other instanceof RoleOrgSaveDTO;
    }

    @Override
    public int hashCode() {
       /* int PRIME = true;*/
        int result = 1;
        Object $roleId = this.getRoleId();
        result = result * 59 + ($roleId == null ? 43 : $roleId.hashCode());
        Object $orgId = this.getOrgId();
        result = result * 59 + ($orgId == null ? 43 : $orgId.hashCode());
        return result;
    }

    public static class RoleOrgSaveDTOBuilder {
        private Long roleId;
        private Long orgId;

        RoleOrgSaveDTOBuilder() {
        }

        public RoleOrgSaveDTO.RoleOrgSaveDTOBuilder roleId(final Long roleId) {
            this.roleId = roleId;
            return this;
        }

        public RoleOrgSaveDTO.RoleOrgSaveDTOBuilder orgId(final Long orgId) {
            this.orgId = orgId;
            return this;
        }

        public RoleOrgSaveDTO build() {
            return new RoleOrgSaveDTO(this.roleId, this.orgId);
        }

        @Override
        public String toString() {
            return "RoleOrgSaveDTO.RoleOrgSaveDTOBuilder(roleId=" + this.roleId + ", orgId=" + this.orgId + ")";
        }
    }
}
